{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 27,
   "metadata": {},
   "outputs": [],
   "source": [
    "import numpy as np\n",
    "import matplotlib.pyplot as plt\n",
    "import tensorflow.compat.v1 as tf\n",
    "tf.disable_v2_behavior()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 28,
   "metadata": {},
   "outputs": [],
   "source": [
    "learn_rate=0.001\n",
    "training_epochs=1000\n",
    "reg_lambda=0.\n",
    "x_dataset=np.linspace(-1,1,101)\n",
    "num_coeffs=9\n",
    "y_dataset_params=[0.]*num_coeffs\n",
    "y_dataset_params[2]=1\n",
    "y_dataset=0\n",
    "for i in range(num_coeffs):\n",
    "    y_dataset +=y_dataset_params[i]*np.power(x_dataset,i)\n",
    "y_dataset += np.random.randn(*x_dataset.shape)*0.3    "
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 29,
   "metadata": {},
   "outputs": [],
   "source": [
    "def split_dataset(x_dataset,y_dataset,radio):\n",
    "    arr=np.arange(x_dataset.size)\n",
    "    np.random.shuffle(arr)\n",
    "    num_train=int(radio* x_dataset.size)\n",
    "    x_train=x_dataset[arr[0:num_train]]\n",
    "    x_test=x_dataset[arr[num_train:x_dataset.size]]\n",
    "    y_train=y_dataset[arr[0:num_train]]\n",
    "    y_test=y_dataset[arr[num_train:x_dataset.size]]\n",
    "    return x_train,x_test,y_train,y_test\n",
    "    \n",
    "    \n",
    "    "
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 30,
   "metadata": {},
   "outputs": [],
   "source": [
    "(x_train,x_test,y_train,y_test)=split_dataset(x_dataset,y_dataset,0.7)\n",
    "X=tf.placeholder(tf.float32)\n",
    "Y=tf.placeholder(tf.float32)\n",
    "def model(X,w):\n",
    "    terms=[]\n",
    "    for i in range(num_coeffs):\n",
    "        term = tf.multiply(w[i],tf.pow(X,i))\n",
    "        terms.append(term)\n",
    "    return tf.add_n(terms)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 31,
   "metadata": {},
   "outputs": [],
   "source": [
    "w=tf.Variable([0.]*num_coeffs,name='parameters')\n",
    "y_model=model(X,w)\n",
    "cost=tf.div(tf.add(tf.reduce_sum(tf.square(Y-y_model)),\n",
    "                  tf.multiply(reg_lambda,tf.reduce_sum(tf.square(w)))),\n",
    "           2*x_train.size)\n",
    "train_op=tf.train.GradientDescentOptimizer(learn_rate).minimize(cost)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 32,
   "metadata": {},
   "outputs": [],
   "source": [
    "sess=tf.Session()\n",
    "init=tf.global_variables_initializer()\n",
    "sess.run(init)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 33,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "0.0\n",
      "0.039012976\n",
      "0.010101010101010102\n",
      "0.028875483\n",
      "0.020202020202020204\n",
      "0.025948893\n",
      "0.030303030303030304\n",
      "0.024868786\n",
      "0.04040404040404041\n",
      "0.024406724\n",
      "0.05050505050505051\n",
      "0.024195196\n",
      "0.06060606060606061\n",
      "0.024099067\n",
      "0.07070707070707072\n",
      "0.024059186\n",
      "0.08080808080808081\n",
      "0.024045968\n",
      "0.09090909090909091\n",
      "0.024043465\n",
      "0.10101010101010102\n",
      "0.024042876\n",
      "0.11111111111111112\n",
      "0.024039483\n",
      "0.12121212121212122\n",
      "0.024030995\n",
      "0.13131313131313133\n",
      "0.024016546\n",
      "0.14141414141414144\n",
      "0.023996098\n",
      "0.15151515151515152\n",
      "0.023970068\n",
      "0.16161616161616163\n",
      "0.023939092\n",
      "0.17171717171717174\n",
      "0.023903873\n",
      "0.18181818181818182\n",
      "0.023865128\n",
      "0.19191919191919193\n",
      "0.023823509\n",
      "0.20202020202020204\n",
      "0.023779621\n",
      "0.21212121212121213\n",
      "0.023733998\n",
      "0.22222222222222224\n",
      "0.023687057\n",
      "0.23232323232323235\n",
      "0.023639161\n",
      "0.24242424242424243\n",
      "0.02359074\n",
      "0.25252525252525254\n",
      "0.023541896\n",
      "0.26262626262626265\n",
      "0.023492943\n",
      "0.27272727272727276\n",
      "0.023444146\n",
      "0.2828282828282829\n",
      "0.023395276\n",
      "0.29292929292929293\n",
      "0.023346793\n",
      "0.30303030303030304\n",
      "0.023298834\n",
      "0.31313131313131315\n",
      "0.02325136\n",
      "0.32323232323232326\n",
      "0.023204362\n",
      "0.33333333333333337\n",
      "0.023157796\n",
      "0.3434343434343435\n",
      "0.023111777\n",
      "0.3535353535353536\n",
      "0.02306657\n",
      "0.36363636363636365\n",
      "0.023021879\n",
      "0.37373737373737376\n",
      "0.022977734\n",
      "0.38383838383838387\n",
      "0.022934409\n",
      "0.393939393939394\n",
      "0.022891589\n",
      "0.4040404040404041\n",
      "0.02284938\n",
      "0.4141414141414142\n",
      "0.022807993\n",
      "0.42424242424242425\n",
      "0.022767184\n",
      "0.43434343434343436\n",
      "0.022727013\n",
      "0.4444444444444445\n",
      "0.022687413\n",
      "0.4545454545454546\n",
      "0.022648543\n",
      "0.4646464646464647\n",
      "0.022610262\n",
      "0.4747474747474748\n",
      "0.022572614\n",
      "0.48484848484848486\n",
      "0.022535766\n",
      "0.494949494949495\n",
      "0.022499269\n",
      "0.5050505050505051\n",
      "0.022463668\n",
      "0.5151515151515152\n",
      "0.022428472\n",
      "0.5252525252525253\n",
      "0.022393625\n",
      "0.5353535353535354\n",
      "0.022359546\n",
      "0.5454545454545455\n",
      "0.022325935\n",
      "0.5555555555555556\n",
      "0.0222931\n",
      "0.5656565656565657\n",
      "0.022260733\n",
      "0.5757575757575758\n",
      "0.022228861\n",
      "0.5858585858585859\n",
      "0.022197567\n",
      "0.595959595959596\n",
      "0.02216653\n",
      "0.6060606060606061\n",
      "0.022136338\n",
      "0.6161616161616162\n",
      "0.022106383\n",
      "0.6262626262626263\n",
      "0.022077207\n",
      "0.6363636363636365\n",
      "0.02204801\n",
      "0.6464646464646465\n",
      "0.022019887\n",
      "0.6565656565656566\n",
      "0.021991761\n",
      "0.6666666666666667\n",
      "0.02196453\n",
      "0.6767676767676768\n",
      "0.021937244\n",
      "0.686868686868687\n",
      "0.021910721\n",
      "0.696969696969697\n",
      "0.021884354\n",
      "0.7070707070707072\n",
      "0.021858891\n",
      "0.7171717171717172\n",
      "0.021833468\n",
      "0.7272727272727273\n",
      "0.021808892\n",
      "0.7373737373737375\n",
      "0.021784278\n",
      "0.7474747474747475\n",
      "0.021760538\n",
      "0.7575757575757577\n",
      "0.021736698\n",
      "0.7676767676767677\n",
      "0.021713657\n",
      "0.7777777777777778\n",
      "0.021690615\n",
      "0.787878787878788\n",
      "0.021668214\n",
      "0.797979797979798\n",
      "0.021646041\n",
      "0.8080808080808082\n",
      "0.021624316\n",
      "0.8181818181818182\n",
      "0.021603025\n",
      "0.8282828282828284\n",
      "0.021581765\n",
      "0.8383838383838385\n",
      "0.021561302\n",
      "0.8484848484848485\n",
      "0.021540726\n",
      "0.8585858585858587\n",
      "0.021520698\n",
      "0.8686868686868687\n",
      "0.021500887\n",
      "0.8787878787878789\n",
      "0.021481218\n",
      "0.888888888888889\n",
      "0.02146245\n",
      "0.8989898989898991\n",
      "0.02144362\n",
      "0.9090909090909092\n",
      "0.021425243\n",
      "0.9191919191919192\n",
      "0.02140714\n",
      "0.9292929292929294\n",
      "0.021389011\n",
      "0.9393939393939394\n",
      "0.021371635\n",
      "0.9494949494949496\n",
      "0.02135429\n",
      "0.9595959595959597\n",
      "0.02133704\n",
      "0.9696969696969697\n",
      "0.021320546\n",
      "0.9797979797979799\n",
      "0.02130389\n",
      "0.98989898989899\n",
      "0.021287661\n",
      "1.0\n",
      "0.021271985\n"
     ]
    }
   ],
   "source": [
    "for reg_lambda in np.linspace(0,1,100):\n",
    "    for epoch in range(training_epochs):\n",
    "        sess.run(train_op,feed_dict={X:x_train,Y:y_train})\n",
    "    final_cost=sess.run(cost,feed_dict={X:x_test,Y:y_test})\n",
    "    print(reg_lambda)\n",
    "    print(final_cost)\n",
    "sess.close()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 34,
   "metadata": {},
   "out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/MuoOXZ+h4sGJ+kn5Z09txj4Nca4ujrsZMk4G+AByPiL5v2pX3s2n2HGmP+QHL1xCXA08l0VCevzTQ2SSuBPcD7I+Khhu3tPt+8Yntt8lki6WLquebJTl6bdWxJTK8ELqXhO5jDcetEtt+3rM5G9/JH/f/MU8D/AT8ADiTblwH7G9pton4Vx3eoTwXNbT+X+j12v5387zkpxtbyvVvE9nLqX/BXNr3+b6lXDr0v+cDOS/nYLRgf9TP99yZ/x4p07KhPS0RyfO5J/jZldexafYeArcDW5LGAG5P9R2m4amy+71+Kx2uh2G4BfthwnCYX+nxzjG1b0ve91E8ov7koxy15/iFgd9Pr8jhutwGPAc9Sz3FX5/l9c2kFM7OKGOQpHTMz64ITvplZRTjhm5lVhBO+mVlFOOGbmVWEE76ZWUU44ZuZVcT/A9zStoZmv4OnAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "plt.scatter(x_test,y_test)\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.8.5"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 4
}
